package com.hui.java.concurrency;

import java.io.IOException;

/**
 * TODO: 创建一个线程
 *
 * @author chenth
 * @create 2019-04-14 22:16
 **/
public class ProcessCreationQuestion {
    public static void main(String[] args) throws IOException {
        //获取Java Runtime
        Runtime runtime = Runtime.getRuntime();
        //启动计算机
        Process process = runtime.exec("calc");
        Process processs = runtime.exec("cmd -k start http://www.baidu.com");//打开浏览器百度
        //退出
        process.exitValue();

    }
}
